package com.yh.doing.Mediator.demo;

/**
 * @program: design-patterns
 * @description:
 * @author: yangh0597@163.com
 * @date: 2022-11-26 23:53
 * @problem:
 **/
public class ColleagueB extends Colleague {

    public ColleagueB(Mediator mediator) {
        super(mediator);
        this.mediator.setColleagueB(this);
    }

    public void selfB() {
        System.out.println("B selfb");
    }

    public void depA() {
        System.out.println("ColleagueB depB");
        this.mediator.transferA();
    }
}
